<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<title>cpi大数据分析用户登录界面</title>
		<base href="${pageContext.request.contextPath }/">
		<link rel="stylesheet" type="text/css" href="css/login.css"/>
		<script type="text/javascript" src="js/jquery-1.9.1.min.js"></script>
		<script type="text/javascript" src="js/login.js"></script>
	</head>
	<body>
		<div class="logindiv"> 
			<div class="formdiv1"></div>
			<div class="formdiv">
				<form action="loginServlet" method="post" onsubmit="return ck()">
					<div class="formleft">
						<table border="0" style="margin-top: 10px;">
							<tr>
								<td align="right" class="lefttd">用户名：</td>
								<td colspan="2">
								   <input onblur="ckusername()" id="username" name="username" tabindex="1" type="text" placeholder="请输入用户名" value="${username }" /> 
								   <span id="userspan" style="color: red;width: 30px;height: 30px;display: block;text-align: center;line-height: 25px;"></span>
								</td>
							</tr>
							<tr>
								<td colspan="3" style="color:red;font-size:12px;text-align: center;">
								    <c:forEach items="${errlist }" var="item">
								        <c:if test="${item eq '1'}">*用户名不能为空</c:if>
								        <c:if test="${item eq '6'}">*用户名不存在</c:if>
								        <c:if test="${item eq '8'}">*该用户已经被冻结</c:if>
								        <c:if test="${item eq '9'}">*连接数据库出错</c:if>
								    </c:forEach>
								</td>
							</tr>
							<tr>
								<td align="right" class="lefttd">密码：</td>
								<td colspan="2">
									<input onblur="ckuserpwd()" id="userpwd" name="userpwd" tabindex="2" type="password" placeholder="请输入密码" value="${sessionScope.userpwd }"/> 
								    <span id="pwdspan" style="color: red;width: 30px;height: 30px;display: block;text-align: center;line-height: 25px;"></span>
								</td>
							</tr>
							<tr>
								<td colspan="3" style="color:red;font-size:12px;text-align: center;">
									<c:forEach items="${errlist }" var="item">
								        <c:if test="${item eq '2'}">*密码不能为空</c:if>
								        <c:if test="${item eq '7'}">*用户名不存在</c:if>
								    </c:forEach>
								</td>
							</tr>
							<tr>
								<td align="right" class="lefttd">验证码：</td>
								<td class="code"><input onblur="ckcode()" id="code" name="code" tabindex="3" class="code" type="text" placeholder="请输入验证码" /> </td>
								<td style="width: 130px;">
								    <span id="codespan" style="color: red;width: 30px;height: 30px;display: block;text-align: center;line-height: 30px;"></span>
								    <img id="codeimg" class="codeimg" alt="二维码" src="IdentifyingCode" onclick="changeimg()">
								</td>
							</tr>
							<tr>
								<td colspan="3" style="color:red;font-size:12px;text-align: center;">
									<c:forEach items="${errlist }" var="item">
								        <c:if test="${item eq '3'}">*验证码不能为空</c:if>
								        <c:if test="${item eq '4'}">*验证码失效了</c:if>
								        <c:if test="${item eq '5'}">*验证码不正确</c:if>
								    </c:forEach>
								</td>
							</tr>
							<tr style="height: 15px;">
								<td style="padding-left: 78px;font-size: 12px;" colspan="3">
									<input tabindex="4" name="checkbox" class="checkbox" type="checkbox" />记住用户
								</td>
							</tr>
						</table>
					</div>
					<div class="formright">
						<input class="submit" tabindex="5" type="image" src="images/user_botton.gif"  />
					</div>
				</form>
			</div>
		</div>
	</body>
</html>
    